home *** CD-ROM | disk | FTP | other *** search
/ Chip 2007 January, February, March & April / Chip-Cover-CD-2007-02.iso / Pakiet bezpieczenstwa / mini Pentoo LiveCD 2006.1 / mpentoo-2006.1.iso / livecd.squashfs / usr / include / X11 / Xaw / FormP.h < prev    next >
C/C++ Source or Header  |  2006-04-12  |  5KB  |  143 lines

  1. /* $Xorg: FormP.h,v 1.4 2001/02/09 02:03:43 xorgcvs Exp $ */
  2.  
  3. /***********************************************************
  4.  
  5. Copyright 1987, 1988, 1994, 1998  The Open Group
  6.  
  7. Permission to use, copy, modify, distribute, and sell this software and its
  8. documentation for any purpose is hereby granted without fee, provided that
  9. the above copyright notice appear in all copies and that both that
  10. copyright notice and this permission notice appear in supporting
  11. documentation.
  12.  
  13. The above copyright notice and this permission notice shall be included in
  14. all copies or substantial portions of the Software.
  15.  
  16. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
  17. IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
  18. FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL THE
  19. OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
  20. AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
  21. CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
  22.  
  23. Except as contained in this notice, the name of The Open Group shall not be
  24. used in advertising or otherwise to promote the sale, use or other dealings
  25. in this Software without prior written authorization from The Open Group.
  26.  
  27.  
  28. Copyright 1987, 1988 by Digital Equipment Corporation, Maynard, Massachusetts.
  29.  
  30.                         All Rights Reserved
  31.  
  32. Permission to use, copy, modify, and distribute this software and its 
  33. documentation for any purpose and without fee is hereby granted, 
  34. provided that the above copyright notice appear in all copies and that
  35. both that copyright notice and this permission notice appear in 
  36. supporting documentation, and that the name of Digital not be
  37. used in advertising or publicity pertaining to distribution of the
  38. software without specific, written prior permission.  
  39.  
  40. DIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
  41. ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
  42. DIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR
  43. ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
  44. WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
  45. ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
  46. SOFTWARE.
  47.  
  48. ******************************************************************/
  49. /* $XFree86: xc/lib/Xaw/FormP.h,v 1.13 2001/12/14 19:54:40 dawes Exp $ */
  50.  
  51. /* Form widget private definitions */
  52.  
  53. #ifndef _XawFormP_h
  54. #define _XawFormP_h
  55.  
  56. #include <X11/Xfuncproto.h>
  57.  
  58. #include <X11/Xaw/Form.h>
  59. #include <X11/Xaw/XawInit.h>
  60.  
  61. _XFUNCPROTOBEGIN
  62.  
  63. #define XtREdgeType "EdgeType"
  64.  
  65. typedef enum {
  66.     LayoutPending,
  67.     LayoutInProgress,
  68.     LayoutDone
  69. } LayoutState;
  70.  
  71. #define XtInheritLayout                            \
  72. ((Boolean (*)(FormWidget, unsigned int, unsigned int, Bool))_XtInherit)
  73.  
  74. typedef struct {
  75.     Boolean(*layout)(FormWidget, unsigned int, unsigned int, Bool);
  76. #ifndef OLDXAW
  77.     XtPointer extension;
  78. #endif
  79. } FormClassPart;
  80.  
  81. typedef struct _FormClassRec {
  82.     CoreClassPart    core_class;
  83.     CompositeClassPart    composite_class;
  84.     ConstraintClassPart    constraint_class;
  85.     FormClassPart    form_class;
  86. } FormClassRec;
  87.  
  88. extern FormClassRec formClassRec;
  89.  
  90. typedef struct _FormPart {
  91.     /* resources */
  92.     int        default_spacing;    /* default distance between children */
  93.  
  94.     /* private */
  95.     Dimension    old_width, old_height; /* reference value for *_virtual  */
  96.     int        no_refigure;        /* no re-layout while > 0         */
  97.     Boolean    needs_relayout;        /* next time no_refigure == 0     */
  98.     Boolean    resize_in_layout;   /* should layout() do geom request?  */
  99.     Dimension    preferred_width, preferred_height; /* cached from layout */
  100.     Boolean    resize_is_no_op;    /* Causes resize to take not action  */
  101. #ifndef OLDXAW
  102.     XawDisplayList *display_list;
  103.     XtPointer pad[4];    /* for future use and keep binary compatability */
  104. #endif
  105. } FormPart;
  106.  
  107. typedef struct _FormRec {
  108.     CorePart        core;
  109.     CompositePart    composite;
  110.     ConstraintPart    constraint;
  111.     FormPart        form;
  112. } FormRec;
  113.  
  114. typedef struct _FormConstraintsPart {
  115.     /* resources */
  116.     XtEdgeType top, bottom, left, right;/* where to drag edge on resize */
  117.     int        dx;        /* desired horiz offset            */
  118.     int        dy;        /* desired vertical offset        */
  119.     Widget    horiz_base;    /* measure dx from here if non-null    */
  120.     Widget    vert_base;    /* measure dy from here if non-null    */
  121.     Boolean    allow_resize;    /* True if child may request resize    */
  122.  
  123.     /* private */
  124.     short    virtual_width, virtual_height;
  125.     Position    new_x, new_y;
  126.     LayoutState    layout_state;    /* temporary layout state        */
  127.     Boolean    deferred_resize;/* was resized while no_refigure is set */
  128. #ifndef OLDXAW
  129.     short    virtual_x, virtual_y;
  130.     XtPointer    pad[2];        /* leave some space for further optimizations
  131.                  * in the form widget geometry
  132.                  */
  133. #endif
  134. } FormConstraintsPart;
  135.  
  136. typedef struct _FormConstraintsRec {
  137.     FormConstraintsPart    form;
  138. } FormConstraintsRec, *FormConstraints;
  139.  
  140. _XFUNCPROTOEND
  141.  
  142. #endif /* _XawFormP_h */
  143.